package namedemo1;

import com.alibaba.nacos.api.exception.NacosException;
import com.alibaba.nacos.api.naming.NamingFactory;
import com.alibaba.nacos.api.naming.NamingService;

import java.io.IOException;

public class registry1 {
    public static void main(String[] args) throws NacosException, IOException {

        NamingService namingService = NamingFactory.createNamingService("localhost:8848");
        namingService.registerInstance("app1","1.1.1.1",8888);
        System.in.read();
    }
}
